import cn.kgc.game.pojo.Equip;
import cn.kgc.game.pojo.Player;
import org.junit.jupiter.api.Test;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class game {
    ApplicationContext context=new ClassPathXmlApplicationContext("applicationContext.xml");
    Player player=(Player) context.getBean("kjlmz");
    @Test
    public void test1(){

        player.show();

    }
    @Test
    public void test2(){
        Equip lmzh=(Equip) context.getBean("lmzh");
        System.out.println(lmzh.getName()+"[攻速增效："+lmzh.getSpeedPlus()+"；攻击增效："+lmzh.getAttackPlus()+"；防御增效："+lmzh.getDefencePlus()+"]");
    }

    @Test
    public void test3(){
        Equip equip=(Equip) context.getBean("lmzh");
        player.updateRing(equip);
        player.updateRing(equip);
        player.show();
    }
}
